<?xml version="1.0" encoding="UTF-8"?>
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
                xmlns:ui="http://java.sun.com/jsf/facelets"
                xmlns:p="http://primefaces.org/ui"
                xmlns:f="http://xmlns.jcp.org/jsf/core"
                xmlns:sec="http://www.springframework.org/security/tags">
    <f:loadBundle var="msg" basename="admin"/>
    <ul class="nav navbar-nav">
        <li>
            <p:link outcome="/index" title="#{msg['menu.home']}" onclick="clearBreadCrumbs()">
                <i class="fa fa-home"/>
                <span>#{msg['menu.home']}</span>
            </p:link>
        </li>
        <li>
            <p:link outcome="/car/car-list" title="#{msg['menu.cars']}">
                <i class="fa fa-car"/>
                <span>#{msg['menu.cars']}</span>
            </p:link>
        </li>

        <li class="dropdown">
            <a href="#" class="dropdown-toggle" data-toggle="dropdown">
                <i class="fa fa-files-o"/>
                <span>Test Toggle</span>
                <span class="caret"/>
            </a>
            <ul class="dropdown-menu" role="menu">
                <li>
                    <p:link outcome="/toggle/test1" title="test1">
                        <i class="fa fa-users"/>
                        <span>test1</span>
                    </p:link>
                </li>
                <sec:authorize access="hasRole('ROLE_USER')">
                    <li>
                        <p:link outcome="/toggle/test2" title="test2">
                            <i class="fa fa-user-circle"/>
                            <span>test2</span>
                        </p:link>
                    </li>
                </sec:authorize>
            </ul>
        </li>
    </ul>

</ui:composition>